|
|
Component
InterruptVector
Interrupt vector handled in user code
Component Level: Peripheral Initialization
Typical Usage:
(Examples of a typical usage of the component in user code.
For more information please
see the page Component Code
Typical Usage.)
Required component name is "IV1" and the ISR name is "OnInterrupt".
(1)
MAIN.C
unsigned int IntCnt=0;
__interrupt void OnInterrupt(void)
{
IntCnt++; /* Increment counter */
}
void main(void)
{
/* Wait for 50 events */
while (IntCnt < 50);
}
|